package impl

import (
	"github.com/my/repo/Desktop/Go15/project/vblog/apps/blog"
	"github.com/my/repo/Desktop/Go15/project/vblog/conf"
	"github.com/my/repo/Desktop/Go15/project/vblog/ioc"
	"gorm.io/gorm"
)

func init() {
	ioc.Controller.Registry(blog.AppName, &BlogServiceImpl{})
}

type BlogServiceImpl struct {
	db *gorm.DB
}

func (i *BlogServiceImpl) Init() error {
	i.db = conf.C().MySQL.GetDB()
	return nil
}